<template>
  <template v-if="type === 'nibp'">
    <span :style="{'font-size': `${props.fontSize}px`}">{{store.personNibpReview(props.deviceId).ns && store.personNibpReview(props.deviceId).ns  || '--'}}/{{ store.personNibpReview(props.deviceId).nd || '--'}} </span>({{store.personNibpReview(props.deviceId).nm || '--'}})
  </template>
  <span v-else :style="{'font-size': `${props.fontSize}px`}">{{ (store.personValueData(props.deviceId)?.[props.type] && store.personValueData(props.deviceId)?.[props.type]!==255) ? store.personValueData(props.deviceId)?.[props.type] : '--' }}</span>
</template>
<script setup lang="ts">
import {useEquipmentInfoStore} from '@/stores/equipment-info-store'
const store = useEquipmentInfoStore()
const props = defineProps({
  deviceId: {
    type: String,
    default: 'ZCXK001'
  },
  type: {
    type: String,
    default: 'hr'
  },
  fontSize: {
    type: Number,
    default: 28
  }
}) as {
  deviceId: string,
  type: string,
  fontSize: number
}
</script>
<style lang="less" scoped>
span {
  font-weight: 600;
  margin-right: 8px;
}
</style>
